package com.qinhao.loveCrowdFunding.controller;

import com.qinhao.loveCrowdFunding.handler.MyMessageHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@RequestMapping("/test")
public class TestController {

    @Autowired
    MyMessageHandler handler;

    @ResponseBody
    @RequestMapping("/get1")
    public String send(String name){
        handler.sendMessageToUser("zhaoshouyun", "服务端发送的内容:"+name);
        return "success";
    }
}
